/*codeup 1934²éÕÒx 
ÊäÈëÒ»¸öÊýn 1<=n<=200,È»ºóÊäÈën¸öÊýÖµ¸÷²»ÏàÍ¬µÄÊý£¬ÔÚÊäÈëÒ»¸öÖµx£¬
Êä³öÕâ¸öÖµÔÚÕâ¸öÊý×éÖÐµÄÏÂ±ê£¨´Ó 0¿ªÊ¼£¬Èô²»ÔÙÊý×éÖÐÔòÊä³ö-1£© 

Êä³ö¶íÊ½£º
²âÊÔÊý¾ÝÓÐ¶à×é£¬ÊäÈën£¨1<= n <=200£©£¬½Ó×ÅÊäÈën¸öÊý£¬È»ºóÊäÈëx

Êä³ö¸ñÊ½£º
¶ÔÓÚÃ¿×éÊäÈë£¬ÇëÊä³ö½á¹û

 
ÑùÀýÊäÈë£º
4
1 2 3 4
3

ÑùÀýÊä³ö£º
2
 
*/

 
#include<cstdio>
const int maxn = 210;
int a[maxn]; 
int main(){
	int n,x;
	while(scanf("%d",&n) != EOF){
		for(int i = 0; i < n; i++){
			scanf("%d",&a[i]);  //ÊäÈën¸öÊý×Ö 
		}
		scanf("%d",&x);
		int k;  //ÔÚÍâÃæint k ÒòÎªÒªÅÐ¶Ïa[k]ÊÇ·ñÕÒµ½ 
		for(k = 0; k < n; k++){  //±éÀúÊý×é 
			if(a[k] == x){  
				printf("%d\n",k); //Êä³öÏÂ±ê 
				break;  //Ò»µ©ÕÒµ½£¬¾ÍÍË³ö²éÕÒ 
			}
		}
		if(k == n){  //  Èç¹ûÑ­»·Ö±µ½½áÊø£¬Ã»ÓÐÕÒµ½ 
			printf("-1\n");  //Êä³ö-1 
		}
	}
	return 0;
} 
